Title Banner


Technical Q&A's


GXPD 42 - Setting GX Paper Types (25-Oct-96)


Q From my application, I need to create a new papertype object on the fly and set the format object for a specific page to use that papertype. I see that there is a GXGetFormatPaperType call but no GXSetFormatPaperType call. Since each page that my user creates could need its own papertype, I need some way to set up the paper type and then set the page size for each page to that new paper type. How do I do this?

A You are correct: there is no GX API that lets you set the paper type format. However, you can achieve this functionality by following these steps:
  1. Call GXNewPaperType to set up the new paper type that your user has created on the fly.
  2. Call GXGetFormatPaperType to get the currently set paper type.
  3. Call GXCopyPaperType to place the new paper type in instead of the old paper type.
  4. Call GXChangedFormat to let GX know that the format has changed.
Sorry this isn't better documented!

--Ingrid Kelly
devsupport@apple.com

Technical Support
Technical Q&As
Previous Question | Contents | Next Question

Navigation graphic, see text links

Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help